by Cary Clark, Georgiann Delaney, Herb Derby, Michael Fairman, Pablo Fernicola, Dave Good, Josh Horwich, Barton House, Robert Johnson, Keith McGreggor, Mike Reed, Oliver Steele, David Van Brink, Chris Yerga
Copyright 1987 - 1994 Apple Computer, Inc. All rights reserved. */
#pragma once
#ifndef graphicsDebuggingIncludes
#define graphicsDebuggingIncludes
#ifndef graphicsTypesIncludes
#include "graphics types.h"
#endif
#ifndef graphicsLinkageIncludes
#include "graphics linkage.h"
#endif
enum gxValidationLevels {
/* These levels tell how to validate routines. Choose one. */
gxNoValidation = 0x00, /* no validation */
gxPublicValidation = 0x01, /* check parameters to public routines */
gxInternalValidation = 0x02, /* check parameters to internal routines */
/* These levels tell how to validate types. Choose one. */
gxTypeValidation = 0x00, /* check types of objects */
gxStructureValidation = 0x10, /* check fields of private structures */
gxAllObjectValidation = 0x20, /* check every object over every call */
/* These levels tell how to validate memory manager blocks. Choose any combination. */
gxNoMemoryManagerValidation = 0x0000,
gxApBlockValidation = 0x0100, /* check the relevant block structures after each memory mgr. call */
gxFontBlockValidation = 0x0200, /* check the system gxHeap as well */
gxApHeapValidation = 0x0400, /* check the memory manager’s gxHeap after every mem. call */
gxFontHeapValidation = 0x0800, /* check the system gxHeap as well */
gxCheckApHeapValidation = 0x1000, /* check the memory manager’s gxHeap if checking routine parameters */
gxCheckFontHeapValidation = 0x2000 /* check the system gxHeap as well */
} ;
typedef long gxValidationLevel;
enum gxDrawErrors {
no_draw_error,
/* gxShape type errors */
shape_emptyType,
shape_inverse_fullType,
rectangle_zero_width,
rectangle_zero_height,
polygon_empty,
path_empty,
bitmap_zero_width,
bitmap_zero_height,
text_empty,
glyph_empty,
layout_empty,
picture_empty,
/* general gxShape errors */
shape_no_fill,
shape_no_enclosed_area,
shape_no_enclosed_pixels,
shape_very_small,
shape_very_large,
shape_contours_cancel,
/* gxStyle errors */
pen_too_small,
text_size_too_small,
dash_empty,
start_cap_empty,
pattern_empty,
textFace_empty,
shape_primitive_empty,
shape_primitive_very_small,
/* gxInk errors */
transfer_equals_noMode,
transfer_matrix_ignores_source,
transfer_matrix_ignores_device,
transfer_source_reject,
transfer_mode_ineffective,
colorSet_no_entries,
bitmap_colorSet_one_entry,
/* gxTransform errors */
transform_scale_too_small,
transform_map_too_large,
transform_move_too_large,
transform_scale_too_large,
transform_rotate_too_large,
transform_perspective_too_large,
transform_skew_too_large,
transform_clip_no_intersection,
transform_clip_empty,
transform_no_viewPorts,
/* gxViewPort errors */
viewPort_disposed,
viewPort_clip_empty,
viewPort_clip_no_intersection,
viewPort_scale_too_small,
viewPort_map_too_large,
viewPort_move_too_large,
viewPort_scale_too_large,
viewPort_rotate_too_large,
viewPort_perspective_too_large,
viewPort_skew_too_large,
viewPort_viewGroup_offscreen,
/* gxViewDevice errors */
viewDevice_clip_no_intersection,
viewDevice_scale_too_small,
viewDevice_map_too_large,
viewDevice_move_too_large,
viewDevice_scale_too_large,
viewDevice_rotate_too_large,
viewDevice_perspective_too_large,
viewDevice_skew_too_large
};
typedef long gxDrawError;
typedef boolean (*gxUserDebugFunction)(const char *str, long message, long reference);